package me.idashu.attg.persistence;

import java.util.List;
import java.util.Map;

import me.idashu.attg.domain.GroupEntity;
import me.idashu.attg.domain.RoleEntity;
import me.idashu.attg.domain.UserEntity;

public interface UserMapper {
	
	void insertUserEntity(UserEntity userEntity);
	
	
	UserEntity getUser(UserEntity user);

	List<UserEntity> getAllShop();
	
	/**
	 * 根据用户名邮箱查询用户记录
	 * @param userName
	 * @return
	 */
	public int getCountByEmail(String email);
	/**
	 * 分页查询用户列表
	 * @param pageEntity
	 * @return
	 */
	public List<UserEntity> getUerEntityByPage(Map<String, Object> map);
	/**
	 * 获取所有用户的数量
	 * @return
	 */
	public int getCountAllUserEntity(UserEntity userEntity);
	/**
	 * 删除用户
	 * @param userId
	 */
	public void deleteUserEntity(int userId);
	/**
	 * 修改用户状态
	 * @param userId
	 */
	public void updateUserStatus(UserEntity userEntity);
	
	public int userLevelCount();
	
	public List<RoleEntity> userLevelList(Map<String, Object> map);
	
	public void deleteUserLevel(int roleId);
	
	public List<GroupEntity> getAllGroup();
	
	public int getCountByRoleName(String rolename);
	
	public void addUserLevelInfo(RoleEntity roleEntity);
	
	public RoleEntity getRole(int roleId);
	
	public void updateUserLevelInfo(RoleEntity roleEntity);
	
	public UserEntity findOneUserById(long id);
	
	public void updatePasswordById(UserEntity userEntity);
	
	public void register(UserEntity userEntity);
	
	public List<UserEntity> searchUsers(Map<String, Object> map);
	
	public int searchCountUsers(UserEntity userEntity);
	
	public void updateSetAttenById(UserEntity userEntity);
	
	public int userCount();
	
	public List<UserEntity> userList(Map<String, Object> map);
	
	public void forbiddenUser(int user_id);
	
	public List<UserEntity> partUserList(Map<String, Object> map);
	
	public void visitorToMember(UserEntity userEntity);
	
	public int insertUserEntityYouKe(UserEntity userEntity);
	
	public void updateUserEntityLocation(UserEntity userEntity);
	
}
